import { BrowserRouter, Routes, Route } from 'react-router-dom';
import { ConfigProvider } from 'antd';
import zhCN from 'antd/locale/zh_CN';
import BasicLayout from './layouts/BasicLayout';
import MembersList from './pages/members/MembersList';
import OrdersList from './pages/orders/OrdersList';
import DishesList from './pages/dishes/DishesList';
import ActivitiesList from './pages/activities/ActivitiesList';
import PromotionsList from './pages/promotions/PromotionsList';
import CouponsList from './pages/coupons/CouponsList';
import Analytics from './pages/Analytics';

function App() {
  return (
    <ConfigProvider locale={zhCN}>
      <BrowserRouter>
        <Routes>
          <Route path="/" element={<BasicLayout />}>
            <Route index element={<Analytics />} />
            <Route path="orders" element={<OrdersList />} />
            <Route path="members" element={<MembersList />} />
            <Route path="dishes" element={<DishesList />} />
            <Route path="activities" element={<ActivitiesList />} />
            <Route path="promotions" element={<PromotionsList />} />
            <Route path="coupons" element={<CouponsList />} />

          </Route>
        </Routes>
      </BrowserRouter>
    </ConfigProvider>
  );
}

export default App;
